Add support for conditionally linking dependencies based on platform#1087
Conversation
|
Spitballing here: What if we changed the other field to be called
|
yonaskolb
left a comment
There was a problem hiding this comment.
Thanks @daltonclaybrook. I agree with the rename of platformFilter, so please proceed. It can be marked as a breaking change in the changelog.
There was a problem hiding this comment.
Can we add a sort to make this deterministic. And I also don't think the Array init is required
|
@yonaskolb Just pushed up those changes. How do you feel about the name of the new field (currently " |
|
@yonaskolb Please let me know what the next steps are on this. I'd really like to get this landed since my team needs it for an upcoming project. |
Yes, let's rename this to |
2ca3e65 to
2d8a7c0
Compare
yonaskolb
left a comment
There was a problem hiding this comment.
Great, thanks @daltonclaybrook!
This PR makes it possible to conditionally link dependencies based on a specified list of platforms. It addresses an issue raised in #951 that the "platform filter" parameter in Xcode is currently not granular enough to prevent a framework from linking against tvOS and watchOS targets.
This is currently implemented as a new field on
DependencycalledconditionalPlatforms. In all honestly, I would prefer that the existingplatformsetting be renamed to something likeplatformFilterto disambiguate from this new setting, but I'm open to suggestions.(cc: @raptorxcz, @yonaskolb, @jlott1)